CC=gcc
FLAGS=
OPEN=openAdressingHashMap
CHAIN=chainingHashMap

all :
	@echo "\tCompilando Hashs"
	make hash.o
	make hashFunctions.o
	make $(OPEN).o
	make $(CHAIN).o

hash.o : hash.c hash.h
	@echo "\t\tEstruturas base"
	$(CC) -c hash.c

hashFunctions.o : hashFunctions.c hashFunctions.h
	@echo "\t\tAlgumas funções de hash"
	$(CC) -c  hashFunctions.c

$(OPEN).o : $(OPEN).c $(OPEN).h
	@echo "\t\tImplementação de uma Open Adressing Hash Map"
	$(CC) -c $(OPEN).c

$(CHAIN).o : $(CHAIN).c $(CHAIN).h
	@echo "\t\tImplementação de uma Chaining Hash Map"
	$(CC) -c $(CHAIN).c

clean :
	rm -f $(OPEN).o
	rm -f $(CHAIN).o
	rm -f hash.o
	rm -f hashFuctions.o

test : test.c hash.o hashFunctions.o $(CHAIN).o
	gcc test.c -o test hash.o hashFunctions.o $(CHAIN).o ../lists/linked-list.o ../../io/logs/logSystem.o
